JavaScript

{dialog.object}populateDropdownBox Method

Syntax

{dialog.Object}.populateDropdownBox(controlName,data,clearExistingData);

Arguments

controlName

Name of the control (must be uppercase)

data

A Javascript array of the choices

clearExistingData

True or false. Existing choices are cleared out if true

Description

Populates the choices in a Dropdownbox control.

Example

Populate the choices in the Dropdown Box for the 'COMPANY' field. Add the new choices to the existing choices.

{dialog.Object}.populateDropdownBox('COMPANY',['A2','B2','C2'],false);

Populate the choices in the Dropdown Box for the 'COMPANY' field. Replace the existing choices. Each new choice that is added has both a display and stored value.

{dialog.Object}.populateDropdownBox('COMPANY',[['alpha 2','A2'],['beta 2','B2'],['display for c','C2']],true);

See Also